<?php
if(!(isset($_COOKIE['username']) && $_COOKIE['userid']&& $_COOKIE['userrole']))
{
    header('Location: index.html');
    exit;
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="icon" href="favicon.ico">

    <title>Keeva Migration</title>

    <!-- Bootstrap core CSS -->
    <link href="dist/css/bootstrap.min.css" rel="stylesheet">
    	<link href="assets/css/style.css" rel="stylesheet">

    <script src="assets/js/jquery.min.js"></script>
    <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
    <link href="assets/css/ie10-viewport-bug-workaround.css" rel="stylesheet">

    <!-- Custom styles for this template -->
    <link href="assets/css/dashboard.css" rel="stylesheet">
    <link href="dist/dist-bootstrap-table/bootstrap-table.min.css" rel="stylesheet"/>
    <script src="dist/dist-bootstrap-table/bootstrap-table.min.js"></script>
    <script src="dist/dist-bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>

    <link href="dist/dist-select2/select2.min.css" rel="stylesheet" />
    <script src="dist/dist-select2/select2.full.min.js"></script>
    
    <link type="text/css" rel="stylesheet" href="assets/bootstrap-fileinput-master/css/fileinput.css" />
		<script type="text/javascript" src="assets/bootstrap-fileinput-master/js/fileinput.js"></script>
		<script type="text/javascript" src="assets/bootstrap-fileinput-master/js/locales/zh.js"></script>

    <script src="dist/dist-validator/js/bootstrapValidator.min.js"></script>
    <link href="dist/dist-validator/css/bootstrapValidator.min.css" rel="stylesheet" />

    <script src="dist/js/bootbox.min.js"></script>

    <!-- Just for debugging purposes. Don't actually copy these 2 lines! -->
    <!--[if lt IE 9]><script src="assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
    <script src="assets/js/ie-emulation-modes-warning.js"></script>

	<link href="assets/bootstrap-datepicker-1.6.4-dist/css/bootstrap-datepicker.css" rel="stylesheet"/>
    <script src="assets/bootstrap-datepicker-1.6.4-dist/js/bootstrap-datepicker.js"></script>
    <script src="assets/bootstrap-datepicker-1.6.4-dist/locales/bootstrap-datepicker.zh-CN.min.js"></script>

	
    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->

    <!-- Bootstrap core JavaScript
================================================== -->
    <!-- Placed at the end of the document so the pages load faster -->
    <script>window.jQuery || document.write('<script src="assets/js/vendor/jquery.min.js"><\/script>')</script>
    <script src="dist/js/bootstrap.min.js"></script>
    <!-- Just to make our placeholder images work. Don't actually copy the next line! -->
    <script src="assets/js/vendor/holder.min.js"></script>
    <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
    <script src="assets/js/ie10-viewport-bug-workaround.js"></script>

    <script src="assets/js/app.js"></script>
</head>

<body id="bd">

<nav class="navbar navbar-inverse navbar-fixed-top">
    <div class="container-fluid">
        <div class="navbar-header">
            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
                <span class="sr-only">Toggle navigation</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
            <a class="navbar-brand" href="#">Keeva Migration</a>
        </div>
        <div id="navbar" class="navbar-collapse collapse">
            <ul class="nav navbar-nav navbar-right">

                <?php if($_COOKIE['userrole']=="1") {
                ?>
                <li><a href="main.php">报告列表</a></li>
                <li><a href="users.php">用户管理</a></li>
                <!--<li><a href="roles.php">角色</a></li>-->
               <!-- <li><a href="server.php">服务器</a></li>-->
                <!--<li><a href="industry.php">行业</a></li>-->
                <?php
                }?>
                <?php if($_COOKIE['userrole']!="1") {
                ?>
                <li><a href="briefing.php">首页</a></li>
                <li><a href="javascript:gotomain();">报告列表</a></li>
                <?php
                }?>
                <li><a href="#" onclick="changepwd('<?php echo $_COOKIE['userid']?>')">修改密码</a></li>
                <li><a href="api.php?method=logout">注销</a></li>
            </ul>
            <!--          <form class="navbar-form navbar-right">-->
            <!--            <input type="text" class="form-control" placeholder="Search...">-->
            <!--          </form>-->
        </div>
    </div>
</nav>